All Questions
3 questions
5votes
3answers
9kviews
Is it necessary for a boolean to be "false" by default?
For example, to store whether sound is on, I have a boolean originally named "isSoundOn": private boolean isSoundOn=true; however, the default value of boolean is false, but I want my application to ...
0votes
0answers
218views
Qt Naming Schemes for returns of boolean member variables: enabled(); vs isEnabled(); ?
In building my classes, I have noticed that I have not been very consistent about naming my boolean returns. In Qt; I notice that many of their classes use the is prefix, but checking their coding ...
67votes
2answers
60kviews
Should I always use "is" as prefix for boolean variables? [closed]
Should I always use is as prefix for boolean variables? What about booleans that indicate something in past? Should I write isInitialized or wasInitialized? Should I write for properties IsManyMembers ...